﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace NETMovie.Entities
{
    public partial class User
    {
        public bool IsValid
        {
            get { return (GetRuleViolations().Count() == 0); }
        }

        public IEnumerable<string> GetRuleViolations()
        {
            yield break;
        }

        public void Update(User user)
        {
            this.Email = user.Email;
            this.AddressLine1 = user.AddressLine1;
            this.AddressLine2 = user.AddressLine2;
            this.City = user.City;
            //this.Country = user.Country;
            this.PostalCode = user.PostalCode;
        }
    }
}
